<template>
  <div class="box">
    <van-card
      num="2"
      :price="item.minPrice"
      :desc="item.name"
      :title="item.name"
      :thumb="item.pic"
      v-for="(item, index) in getStoreList"
      :key="index"
      v-show="index<=1"
      @click="onClick()"
    />
  </div>
</template>

<script>
export default {
  data() {
    return {
      getStoreList: [],
    };
  },

  mounted() {
    this.$API.getStoreList().then((res) => {
      console.log(res);
      this.getStoreList = res.data.data;
    });
  },
  methods: {
      onClick(){
        this.$router.push({path:'/bargain'});//跳转全民砍价详情
      }
  },
};
</script>

<style lang='scss'>
.van-tabbar--fixed{
    width: 100%;
    height: 1.2rem;
}
</style>